-- A solution
solution "OPCUA_PUB"
	configurations { "Release", "Debug" }

	project "OPCUA_PUB"
		kind "SharedLib"
		language "C++"
		platforms {"Native"}
		location "build_h30"
		targetprefix ""
        targetextension ".h30"
		targetdir "$(SymReleasePath)/DsDrivers/OPCUA_PUB"
		
		files { 
				"./src/**.h", 
				"./src/**.cpp",
				"./src/**.c",
				"./mbedtls/**.c",
				} 
		includedirs { 
						"./",
                        "$(SymLibPath)",
						"./src/mqtt-c",
						"./include/mqtt-c/include",
						"./mbedtls/include",
						"$(STAGING_DIR)/usr/lib/libiconv-full-full/include"
					}
				
		--,"rt","ssl","crypto"
		--links { "Io", "pthread","iconv","mbedtls","mbedcrypto","mbedx509" }
		links { "Io", "pthread","iconv" }
		libdirs {
			"$(SymLibPath)/__SymLib",
			"$(STAGING_DIR)/usr/lib/libiconv-full-full/lib"
		}
		
		-- Using cross compile
		premake.gcc.cc = "arm-openwrt-linux-gcc"
		premake.gcc.cxx = "arm-openwrt-linux-g++"
		premake.gcc.ar = "arm-openwrt-linux-ar"

		defines{"SXPLAT_LINUX_H30"}

		configuration "Debug"
			defines { "DEBUG" }
			flags { "Symbols" }

		configuration "Release"
			defines { "NDEBUG" }
			flags { "Optimize" }


